//导入mysql模块
const mysql = require('mysql2')

//创建数据库连接对象池
const db = mysql.createPool({
    host: 'localhost',
    user: 'root',
    password: '123456',
    port: '3306',
    database: 'chatapp',
})

module.exports = db
